message='file'
file='C:/temp/test2.txt'  
output=open(file,'w')
output.write('testing 1,2,3,4....')

import random

num_objects=int(Prompt('Maximum number of objects to create?','10',true,''))
#x_offset=int(Prompt('X offset','200',true,''))
#y_offset=int(Prompt('y offset','200',true,''))
#z_offset=int(Prompt('z offset','25',true,''))

x_offset = 2000
y_offset = 2000
z_offset = 25

#m = ['Dome','Dome 2','Green glass tower','Glass building','Riddle']


m = ['Green glass tower','Glass building','Riddle']

message = str(CountObjects())

def getx(x):
    output = x_offset*random.uniform(10,500)
    return output

def gety(x):
    output = y_offset*random.uniform(10,500)
    return output

def getz(x):
    output = z_offset
    return output

output.write('')

w = int(random.uniform(10,20))
l = int(random.uniform(10,40))
h = int(random.uniform(80,180))

for y in range(num_objects):
  #for x in range(len(m)):
    obj=AddCube()
    obj.SetPosition(getx(x),gety(y),h/2)
    obj.Rotate(1,1,1)
    obj.ResizeAxis(w,l,h)
    obj.SetMaterial(m[int(random.uniform(0,len(m)))])
    stroutput = 'Create' + str(x) + ',' +  str(getx(x)) + ',' +  str(gety(y)) + ',' +  str(getz(x))
    output.write(stroutput)
    output.write('\n')

output.close